package inter;

import java.util.Iterator;
import java.util.ServiceLoader;

public class Test {
	public static void main(String[] args) {
		ServiceLoader<ITest> loadedParsers = ServiceLoader.load(ITest.class);
		Iterator<ITest> iterator = loadedParsers.iterator();
		int i=1;
		while (iterator.hasNext()) {
			ITest spiService = iterator.next();
			spiService.save("测试"+i);
			i++;
		}
	}
}
